﻿namespace Example.Diagnostics
{
    using System.Diagnostics;

    public static class CustomEventLog
    {
        public static void BadCommand()
        {
            using (var log = new EventLog("Custom", ".", "Custom Company"))
            {
                log.WriteEvent(new EventInstance(0xC00203E9, 2, EventLogEntryType.Error), null as object);
                log.Close();
            }
        }

        public static void CommandDelete(string file, string contains)
        {
            using (var log = new EventLog("Custom", ".", "Custom Company"))
            {
                log.WriteEvent(new EventInstance(0xC00003EC, 2), file, contains);
                log.Close();
            }
        }
    }
}